f = @(x)  0.*(x < pi) +   sin(10*pi*x).*(x > pi& x <= 5*pi)
z= pi:10^-2:10*pi;
length(z)
f= f(z);

fft(f);
figure;
plot(z,f,'or')
figure;
d = 4;
enverlope = hilbert(f);
hold on
plot(abs(enverlope))
plot(-abs(enverlope))
figure;

plot(z,abs(fft(f)),'or')

t=0:0.001:1;
x=sin(2*pi*30*t)+cos(2*pi*35*t)+sin(40*pi*t);
plot(x)
x
s=hilbert(x);
hold 
plot(abs(s))
plot(-abs(s))
